// Copyright 2011 Intergraph Corporation
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

#ifndef _PGSTYPES_HPP_
#define _PGSTYPES_HPP_

#include <basetyps.h>
#include <wtypes.h>
#include <ocidl.h>

const CLSID CLASS_GDatabase = {0x13C71AD3,0xFA0B,0x44F8,{0x90,0xD2,0x34,0x7A,0xA6,0x18,0x73,0x20}};

const IID DIID_GField = {0xA1596D10,0x7602,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GError = {0x1FEC0B90,0x7699,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GIndex = {0x2FA9E2D0,0x76A7,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID__IGCollection = {0x3BD80880,0x7126,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID__IGDynaCollection = {0x05F57EB0,0x720B,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GFields = {0x034D65A0,0x76B4,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GRecordset = {0xBCBD18C0,0x72D2,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GTableDef = {0x9C76DF90,0x76A1,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GIndexes = {0x12C00EE0,0x76B4,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GRecordsets = {0x6CF50B40,0x7126,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GTableDefs = {0xE81F5E20,0x7126,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GErrors = {0x82F5A9E0,0x7127,0x11CF,{0x83,0x57,0x08,0x00,0x36,0x01,0xE5,0xF9}};
const IID DIID_GDatabase = {0x6946F650,0x78F6,0x11CF,{0x83,0xFC,0x08,0x00,0x36,0x83,0x03,0x02}};
const IID DIID_ExtendedPropertySet = {0xF6CDD900,0x2AD4,0x11D0,{0x8C,0x0C,0x00,0x40,0x95,0x41,0xF7,0xA2}};
const IID DIID_LiterarConversionExtension = {0x7A6F7A04,0xC71A,0x4EA1,{0xA8,0x1A,0xDD,0x37,0x7F,0x71,0xEF,0xEA}};

const GUID GID_PointGeometry = {0x0FD2FFC0,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_LineGeometry = {0x0FD2FFC1,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_PolylineGeometry = {0x0FD2FFC2,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_PolygonGeometry = {0x0FD2FFC3,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_BoundaryGeometry = {0x0FD2FFC5,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_GeometryCollection = {0x0FD2FFC6,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_RectangleGeometry = {0x0FD2FFC7,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_OrientedPointGeometry = {0x0FD2FFC8,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_TextPointGeometry = {0x0FD2FFC9,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_ArcGeometry = {0x0FD2FFCA,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_CompositePolylineGeometry = {0x0FD2FFCB,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_CompositePolygonGeometry = {0x0FD2FFCC,0x8CBC,0x11CF,{0xAB,0xDE,0x08,0x00,0x36,0x01,0xB7,0x69}};
const GUID GID_RasterGeometry = {0xC653947E,0xDA9A,0x11CF,{0x82,0x5A,0x08,0x00,0x36,0xFE,0x28,0x02}};

const double gdPrecLim = 0.00005;

class GField;
class GError;
class GIndex;
class _IGCollection;
class _IGDynaCollection;
class GFields;
class GRecordset;
class GTableDef;
class GIndexes;
class GRecordsets;
class GTableDefs;
class GErrors;
class GDatabase;

int GetOrient(double *v1, double *v2);

#endif
